#include "defines.txt"

if (new_room) {
  load.pic(room_no);
  draw.pic(room_no);
  discard.pic(room_no);
  set.horizon(37);
  if (prev_room_no == 6) {
    position(ego,116,112);
  }
  draw(ego);
  show.pic();
}
if (has("key")) {
  if (said("open","door")) {
    print("K.O.");
    new.room(6);
   }
}
if (said("open","door")) {
print("You don't have the key");
}
if (v3 == 14) {
  if (said("look")) {
    print("You are in front of the biri studio.");
    print("There is a car that seems to be waiting for you,, wierd.");
  }
}
if (said("look")) {
  print("You stand in front of the EAST INDIA CONSORTIUM..");
}
if (ego_edge_code == right_edge) {    // ego touching right edge of screen
  new.room(5);
}
if (ego_edge_code == left_edge) {     // ego touching left edge of screen
  new.room(3);
}
if (has("spell book")) {
  if (said("open","book")) {
    print("The spells are as follows-.");
    print("DHOOA: Makes everyone go blind, except you.");
    print("KALI: You can open any door with this one.");
    print("PINKU: You will know the answer to any questions if you use this.");
    print("That's all.");
  }
}
if (has("spell book")) {
  if (said("dhooa")) {
    print("No need of using this now.");
  }
}
if (has("spell book")) {
  if (said("Kali")) {
    print("No need of using this now.");
  }
}
if (has("spell book")) {
  if (said("pinku")) {
    print("No need of using this now.");
  }
}
if (v3 == 14) {

  load.view(2);
  set.view(o2,2);
  position(o2,65,135);
  animate.obj(o2);
  stop.cycling(o2);
  draw(o2);
}
if (said("use","car")) {
  if (posn(o0,65,117,93,137)) {
    erase(o0);
    v3 += 2;
  }
  else {
    print("You are not close enough.");
  }
}
if (v3 == 16) {
  if (said("drive","car")) {
    load.view(2);
    set.view(o2,2);
    position(o2,65,135);
    animate.obj(o2);
    start.cycling(o2);
    draw(o2);
    prevent.input();
    move.obj(o2,158,127,1,f154);
  }
}
if (isset(f154)) {
  print("The car leaves the EAST INDIA CONSORTIUM!");
  reset(f154);
  new.room(9);
}
return();